Skip to content

Improve initialization in the core chart#156

Merged
jacekn merged 1 commit intostellar:mainfrom
jacekn:init
Mar 12, 2026
Merged

Improve initialization in the core chart#156
jacekn merged 1 commit intostellar:mainfrom
jacekn:init

Conversation

@jacekn
Copy link
Copy Markdown
Contributor

@jacekn jacekn commented Mar 11, 2026

This pull request will improve the way we initialize core. After the change new-db will only run if no schema is present. This is a slight behaviour change but it's safer than the existing one. Other that being safer the new version is a drop-in replacement that doesn't require operators to take any action.
The new method also allows operators to customize how core is initialized and also allows for handling of history archives.

This pull request will improve the way we initialize core.
After the change new-db will only run if no schema is present.
This is a slight behaviour change but it's safer than the
existing one. Other that being safer the new version is a
drop-in replacement that doesn't require operators to take
any action.
The new method also allows operators to customize how core
is initialized and also allows for handling of history archives.
Copilot AI review requested due to automatic review settings March 11, 2026 15:49
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the core Helm chart initialization flow so database setup/migrations happen via a configurable init script, aiming to avoid running new-db when a schema already exists and enabling optional history-archive initialization.

Changes:

  • Add .Values.core.initScript and mount/execute it via a new init-scripts ConfigMap and initContainer.
  • Replace the previous new-db initContainer args with an init script that attempts upgrade-db and falls back to new-db.
  • Bump chart version from 0.5.0 to 0.6.0.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.

File Description
charts/core/values.yaml Introduces a configurable init script and default DB init/upgrade logic.
charts/core/templates/core-sts.yaml Switches initContainer to execute the mounted init script and adds the init-scripts volume.
charts/core/templates/core-init-scripts-cm.yaml Adds a ConfigMap to deliver init.sh from values into the pod.
charts/core/Chart.yaml Increments chart version to reflect the behavior change.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Copy Markdown

@wpalmeri wpalmeri left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good improvement!

@jacekn jacekn merged commit 7e9a2d7 into stellar:main Mar 12, 2026
6 checks passed
@jacekn jacekn deleted the init branch March 12, 2026 12:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants